const {
	http
} = uni.$u

// 获取菜单
// console.log(Base64.decode(mpConfig.appSecret))
// 获取微信小程序access_token
export const getAccessToken = (params) => http.get('https://api.weixin.qq.com/cgi-bin/token', {
	params,
	custom: {useApi:true }
});
export const fetchMenu = (params, config = {}) => http.post('/ebapi/public_api/index', params, config)

//------------------登录模块----------------------------------//
export const doLogin = (params, config = {}) => http.post('auth/login', params,{custom: {auth: true}});
// 此处没有使用传入的params参数
export const getSearch = (params = {}) => http.get(hotSearchUrl, {
	id: 2
});
// 此处使用了传入的params参数，一切自定义即可
export const getInfo = (params = {}) => http.post(indexUrl, params);
//获取用户信息
export const getUserInfo = (params = {}) => http.post('designer/user/getUserInfo', params);


